package io.iamting93.code.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @author boting.guo
 * @date 2021/11/30 15:15
 */

@FeignClient(value = "service-email", fallbackFactory = EmailFeignFallbackFactory.class, path = "email")
public interface EmailFeign {

    @GetMapping("/{email}/{code}")
    boolean sendEmail(@PathVariable("email") String emailAddress,
                      @PathVariable("code") String content);
}
